<!-- 开展情况 -->
<template>
  <el-dialog
    title="开展情况"
    width="70%"
    :visible.sync="dialogVisible"
    @close="handlerClose"
  >
    <div class="dialog_main">
      <div class="search">
        <el-form :inline="true" :model="formInline" class="demo-form-inline" size="small">
          <el-form-item label="开展时间">
            <el-date-picker v-model="formInline.time" type="date" :value-format="yyyy-MM-dd" placeholder="选择日期" />
          </el-form-item>
          <el-form-item>
            <el-radio-group v-model="formInline.type" size="small">
              <el-radio-button label="0">所有</el-radio-button>
              <el-radio-button label="1">门诊</el-radio-button>
              <el-radio-button label="2">住院</el-radio-button>
            </el-radio-group>
          </el-form-item>
          <el-form-item>
            <el-button type="primary" @click="onSearch">搜索</el-button>
          </el-form-item>
        </el-form>
      </div>
      <el-table :data="ticketList" stripe>
        <el-table-column label="序号" type="index" width="80" align="center" />
        <el-table-column label="院区" prop="name" align="center" />
        <el-table-column label="科室" prop="projectClassName" align="center" />
        <el-table-column label="医生工号" prop="projectClassName" align="center" />
        <el-table-column label="开单时间" prop="projectClassName" align="center" />
        <el-table-column label="执行数量" prop="projectClassName" align="center" />
      </el-table>
      <pagination v-show="pageInfo.total > 0" :total="pageInfo.total" :page.sync="pageInfo.currentPage" :limit.sync="pageInfo.pageSize" @pagination="onPagination" />
    </div>
  </el-dialog>
</template>

<script>
export default {
  data() {
    return {
      dialogVisible: false,
      formInline: {
        time: '',
        type: '0'
      },
      pageInfo: {
        total: 0,
        currentPage: 1,
        pageSize: 10
      },
      ticketList: []
    }
  },
  methods: {
    handlerClose() {
      this.$emit('update:visible', false)
    },
    open() {
      this.dialogVisible = true
    },
    onSearch() {
      this.pageInfo.pageNum = 1
      this.getInit()
    },
    // 分页
    onPagination(obj) {
      this.pageInfo.currentPage = obj.page
      this.pageInfo.pageSize = obj.limit
      this.getInit()
    },
    getInit() {

    }
  }
}
</script>

<style lang="scss" scoped>
</style>
